package com.rz.paas.test.constant

import android.util.SparseArray
import androidx.core.util.set
import com.rz.paas.test.R

object AppConstant {

    const val ENV_DATA_INDEX = 1
    const val ENCODE_MODE_DATA_INDEX = 2
    const val VIDEO_RENDER_TYPE_DATA_INDEX = 3
    const val RENDER_MODE_INDEX = 4
    const val PUSH_SCREEN_MODE_DATA_INDEX = 5
    const val ENCODE_RESOLUTION_DATA_INDEX = 6
    const val ENCODE_FPS_DATA_INDEX = 7
    const val ENCODE_DIRECTION_DATA_INDEX = 8

    val dataMap = SparseArray<OptionsData>()

    val CUSTOM_ENV = "custom_env"
    val COMMUNICATION_MODE = "communication_mode"
    val CHANNEL_ID = "channel_id"
    val USER_ID = "user_id"

    init {
        dataMap[ENV_DATA_INDEX] =
            OptionsData("env_data", "选择环境","环境", R.array.env_data)


        dataMap[ENCODE_MODE_DATA_INDEX] =
            OptionsData("encode_mode_data", "选择模式", "解码器",R.array.encode_mode_data)

        dataMap[VIDEO_RENDER_TYPE_DATA_INDEX] =
            OptionsData("video_render_type_data", "选择类型","渲染器", R.array.video_render_type_data)

        dataMap[RENDER_MODE_INDEX] =
            OptionsData("render_mode_data", "选择类型", "渲染方式", R.array.render_mode_data)

        dataMap[PUSH_SCREEN_MODE_DATA_INDEX] =
            OptionsData("push_screen_mode_data", "选择类型", "渲染器", R.array.push_screen_mode_data)

        dataMap[ENCODE_RESOLUTION_DATA_INDEX] =
            OptionsData("encode_resolution_data", "选择分辨率", "编码分辨率", R.array.encode_resolution_data)

        dataMap[ENCODE_FPS_DATA_INDEX] =
            OptionsData("encode_fps_data", "选择帧率","编码帧率",  R.array.encode_fps_data)

        dataMap[ENCODE_DIRECTION_DATA_INDEX] =
            OptionsData("encode_direction_data", "选择方向","编码方向",  R.array.encode_direction_data)


    }
}